package com.smartum.mpr.client.event;

import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.user.client.History;
import com.smartum.mpr.client.utils.HistoryHelper;

/**
 * Interface corresponding to {@link LoginEvent}, which fires after successful login.
 */
public class LoginEventHandler implements EventHandler {

    /**
     * Calls {@link com.smartum.mpr.client.utils.HistoryHelper#navigateToken(String adminToken)} method, which will add
     * new token to the {@link History} block.
     */
    void doLoginAdminConsole() {
        HistoryHelper.navigateToken(HistoryHelper.ADMIN_TOKEN);
    }
}
